package main

import (
	"fmt"
	"io/ioutil"
)

func main() {
	filePath1 := "a.txt"
	filePath2 := "b.txt"

	data, err := ioutil.ReadFile(filePath1)
	if err != nil{
		fmt.Println("error = ", err)
		return
	}

	err = ioutil.WriteFile(filePath2, data, 0666)
	if err != nil{
		fmt.Println("err= ", err)
	}
}